import request from '@/utils/request'
export function queryRelatedInterviewByKeywords(keywords){
  return request({
    url: '/teaching/interview/queryRelatedInterviewByKeywords',
    method: 'post',
    data: keywords
  })
}

export function queryRelatedInterview(id,courseContext) {
  return request({
    url: '/teaching/interview/queryRelatedInterview',
    method: 'get',
    params: {id,courseContext}
  })
}
export function queryPercentage() {
  return request({
    url: '/teaching/interview/export/es/percentage',
    method: 'get'
  })
}
export function exportEs() {
  return request({
    url: '/teaching/interview/export/es',
    method: 'get'
  })
}

export function listInterview_masteryDegree(query) {
  return request({
    url: '/teaching/interview/list/mastery_degree',
    method: 'get',
    params: query
  })
}
// 查询高频面试题列表
export function listInterview(query) {
  return request({
    url: '/teaching/interview/list',
    method: 'get',
    params: query
  })
}

// 查询高频面试题详细
export function getInterview(id) {
  return request({
    url: '/teaching/interview/' + id,
    method: 'get'
  })
}

// 新增高频面试题
export function addInterview(data) {
  return request({
    url: '/teaching/interview',
    method: 'post',
    data: data
  })
}

// 修改高频面试题
export function updateInterview(data) {
  return request({
    url: '/teaching/interview',
    method: 'put',
    data: data
  })
}

// 删除高频面试题
export function delInterview(id) {
  return request({
    url: '/teaching/interview/' + id,
    method: 'delete'
  })
}
